//
//  YCShareActionSheet.h
//  DemoActionSheet
//
//  Created by tangkexiong on 16/3/8.
//  Copyright © 2016年 tangkexiong. All rights reserved.
//

#import <UIKit/UIKit.h>

#pragma mark - YCShareActiionSheetItem

@interface YCShareActionSheetItem : NSObject

@property (nonatomic, strong) NSString *mName;
@property (nonatomic, strong) NSString *mImg;

@end

#pragma mark - YCShareActionSheetCell

@interface YCShareActionSheetCell : UICollectionViewCell

@property (weak, nonatomic) IBOutlet UIImageView *imgView;
@property (weak, nonatomic) IBOutlet UILabel *nameLabel;

@end

#pragma mark - YCShareActionSheetDelegate

@class YCShareActionSheet;
@protocol YCShareActionSheetDelegate <NSObject>

@optional
- (void)shareActionSheet:(YCShareActionSheet *)sheet didSelectAtIndex:(NSInteger)index;
- (void)shareActionSheetDidCancel:(YCShareActionSheet *)sheet;

@end

#pragma mark - YCShareActionSheet

/**
 *  分享的ActionSheet
 */
@interface YCShareActionSheet : UIViewController

/// 代理
@property (nonatomic, weak) id<YCShareActionSheetDelegate> myDelegate;

@property (weak, nonatomic) IBOutlet UIView *bgView;
@property (weak, nonatomic) IBOutlet UILabel *titleLabel;
@property (weak, nonatomic) IBOutlet UICollectionView *myCollectionView;
@property (weak, nonatomic) IBOutlet UIPageControl *myPageCtrl;

@property (weak, nonatomic) IBOutlet NSLayoutConstraint *constraintActionViewBottomMargin;
@property (weak, nonatomic) IBOutlet NSLayoutConstraint *constraintActionViewHeight;
@property (weak, nonatomic) IBOutlet NSLayoutConstraint *constraintCollectionViewHeight;

/**
 *  实例方法
 *
 *  @param title     标题
 *  @param itemArray item数组
 *  @param delegate  代理
 *
 *  @return 实例
 */
+ (instancetype)instanceWithTitle:(NSString *)title shareItems:(NSArray *)itemArray delegate:(id<YCShareActionSheetDelegate>)delegate;
/**
 *  显示
 */
- (void)show;

@end

